package com.tzw.controller;

import com.tzw.pojo.ModuleOfProduct;
import com.tzw.service.ModuleOfProductService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.ui.Model;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;

import java.util.List;

/**
 * 客户服务接口
 * */
@Controller
@RequestMapping("/customerService")
public class CustomerServiceController {
    @Autowired
    private ModuleOfProductService moduleOfProductService;
    @GetMapping("/")
    public String aboutView(Model model){
        List<ModuleOfProduct> productList = moduleOfProductService.list();
        model.addAttribute("prdList",productList);
        return "/customer_Service";
    }
}
